<!DOCTYPE html>

<html lang='en'>
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <meta http-equiv="X-UA-Compatible" content="ie=edge">
    <title>Document</title>
    <script src="./lib/react.development16.4.0.js"></script>
    <script src="./lib/react-dom.development16.4.0.js"></script>
    <script src="./lib/babel.min.js"></script>
</head>

<body>
    <div id="app">
    </div>
    <script type="text/babel">
        function myfun(user) {
            return <span>姓名：{user.name}----年龄：{user.age}</span>
        }

        const user = {name:'张三',age:21}

        const el = <h1>元素渲染！！！{myfun(user)}</h1>
        ReactDOM.render(
            el,document.getElementById('app')
        );
    </script>
</body>

</html>